import { createRouter, createWebHashHistory } from 'vue-router';

const router = createRouter({
    // 4. 内部提供了 history 模式的实现。为了简单起见，我们在这里使用 hash 模式。
    history: createWebHashHistory(),
    routes: [{
            path: '/',
            component: () =>
                import ('../pages/myHome/MyHome'),
        },
        {
            path: '/home',
            component: () =>
                import ('../pages/myHome/MyHome'),
        },
        {
            path: '/cart',
            component: () =>
                import ('../pages/myCart/MyCart'),
        },
        {
            path: '/order',
            component: () =>
                import ('../pages/myOrder/MyOrder'),
        },
        {
            path: '/mine',
            component: () =>
                import ('../pages/mine/Mine'),
        },
    ],
});

export default router;